﻿using System;
using System.Reflection;

namespace ConsoleCommand.Commands
{
    class ListResourcesCommand : ICommand
    {
        string assembly;
        
        public ListResourcesCommand(string assembly) { 
            this.assembly=assembly;
        }

        public object Execute() {
            Assembly assembly = Assembly.LoadFrom(this.assembly);
            string[] resourceList = assembly.GetManifestResourceNames();
            return String.Join(Environment.NewLine, resourceList);
        }
    
    }
}
